Skip to content

feat(videoout): expose buffer labels and release replaced frames - #37

Merged
JJenkx merged 7 commits into
mainfrom
feat/videoout-buffer-labels
Oct 14, 2026
Merged

JJenkx merged 7 commits into
mainfrom
feat/videoout-buffer-labels

Conversation

@JJenkx

@JJenkx JJenkx commented Oct 13, 2026 •

Copy link
Copy Markdown
Owner

What

Implement sceVideoOutGetBufferLabelAddress with a port-owned contiguous array of 16 aligned 64-bit labels. Return its actual address and count, reset only newly registered buffer slots, and release the previous displayed buffer's label when its replacement finishes presentation. Black/blank replacements release the previous buffer without indexing a negative buffer number. Ports and reopened generations have separate arrays; label addresses are valid until close.

Route stores through an explicitly exported graphics-driver helper so production NID patching preserves the cross-library call and the memory tracker sees an atomic release store. Null output and invalid/unopened/closed handles return their existing errors while preserving output on failure; successful pointer outputs support unaligned storage.

Astro Bot PPSA21564's bundled driver calls the API with a pointer output and computes base + index * 8. Count and release behavior follow shadPS4's video output and its driver. Exact PS5 scanout timing, concurrent guest stores, error policy and same-buffer repetition remain unverified and are documented in library debt. EOP-flip interrupt registration remains separate and unimplemented.

Tested

  • Full Linux Release build with bundled dependencies and 32 workers.
  • Real X11 Radeon and lavapipe tests check label count/width/alignment, unaligned output canaries, errors and output preservation, registration resets, first-frame retention, replacement release, black/blank frames, port separation and close/reopen generations. Both overlay and actual main-output presentation are exercised.
  • Lifetime, reopen, overlay and bus regressions also passed on both Vulkan drivers.
  • With the release behavior removed, the label regression fails at the replacement-label check; it passes after restoration.
  • Direct production NID OcQybQejHEY passed: count 16, eight-byte entries, zero initial labels, unaligned output canaries, null/closed errors and preserved failure output. The patched graphics store helper also passed. The initial probe lacked param.json; rerunning with Astro's existing staged metadata passed. No guest game code was executed.
  • Four label cases (main and overlay on both drivers), eight related VideoOut cases and 14 affected CPU regressions passed with no skips.
  • Astro still cannot start because three libraries are missing. Unresolved import names decreased from 14 to 13. This is import and host presentation coverage, not a game execution or PS5 equivalence claim.
  • Standalone fork-main conventions passed. Full platform CI passed at aef1b29: Linux 936 passed / 45 skipped; Windows 638 passed / 359 skipped. The two new display-dependent label cases were skipped on both CI runners; their functional validation comes from the local X11 runs above.

Checklist

  • Based on current fork main; no other open PR found implementing this API
  • One topic per PR
  • No code comments added
  • No silent success stubs
  • No assets, notes, images or binaries added
  • No new third-party code
  • Generic per-port buffer labels
  • Depends on: none
  • Unblocks: none
  • AI-assisted: yes

Current upstream validation

Published head d1de55fb3306fe658d34ba7db87ad6b3dfe05977 contains current main d1670009fbfdfe57f8f26ee09ced77fe6b18c2ca. The label implementation is unchanged. Relocated the byte-identical label test function and dispatch entries, registered label modes separately, and placed the debt entry beside related buffer behavior. Merge-tree checks now merge this head cleanly with boykopovar#5539, boykopovar#4863, boykopovar#5239 and boykopovar#5466; none is a dependency. Conventions and whitespace checks pass.

Earlier full Linux and Windows validation passes at head 71d9fe46914512b0c148f9d80317b0428bf14eec. Fresh full Linux and Windows validation passes for this published head; expected skips remain unvalidated.

@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Progress report (d167000 → d1de55f)

📈 System libraries: 88.19% (+0.01%, +1 implemented functions)

✅ 1 implemented
Library Name
libSceVideoOut sceVideoOutGetBufferLabelAddress

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Oct 13, 2026
@github-actions github-actions Bot added agc libSceAgc* prx Other PRX libraries build CMake, submodules, 3rdparty docs Documentation and removed needs rebase Conflicts with main, rebase needed labels Oct 13, 2026
@JJenkx JJenkx added the next-20 Selected next merge candidates; see each PR for current validation label Oct 13, 2026
@JJenkx
JJenkx merged commit 8bbed13 into main Oct 14, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* build CMake, submodules, 3rdparty docs Documentation next-20 Selected next merge candidates; see each PR for current validation prx Other PRX libraries

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant